// 3!=3*2*1
const readline = require("readline-sync");
var num = readline.question("请输入要求阶乘的数字：");
var result = 1;
var str = "";
for(var i=num;i>0;i--){
    result *= i;
    //if(i !== 1){
    //    str+=i+"*";
    //}else{
    //   str += i;
    //}
    str+=i!==1?i+"*":i;
}
console.log(num+"!="+str+"="+result);

